<!DOCTYPE html>
<html lang="en">
<head>
<title><?php echo $title;?></title>
<link rel="shortcut icon" href="<?php echo base_url();?>images/hr_icon.ico" />
<meta name="viewport" content="width=device-width, initial-scale=1.0"/>
<link href="<?php echo base_url();?>css/style.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="<?php echo base_url();?>js/jquery-1.7.2.min.js"></script>
<script type="text/javascript" src="<?php echo base_url();?>js/script.js"></script>

<link href="<?php echo base_url();?>bootstrap/css/bootstrap.min.css" rel="stylesheet" media="screen"/>
<link href="<?php echo base_url();?>bootstrap/css/bootstrap.responsive.min.css" rel="stylesheet" media="screen"/> 
<script type="text/javascript" src="<?php echo base_url();?>bootstrap/js/bootstrap.min.js"></script>

<script type="text/javascript" src="<?php echo base_url();?>js/jquery.tablesorter.js"> </script>
<script type="text/javascript" src="<?php echo base_url();?>js/jquery.tablesorter.pager.js"> </script>		
			 
<link type="text/css" rel="stylesheet" media="screen" href="<?php echo base_url();?>js/validation/validationEngine.jquery.css"/>
<script src="<?php echo base_url();?>js/validation/languages/jquery.validationEngine-en.js" type="text/javascript" charset="utf-8"></script>
<script src="<?php echo base_url();?>js/validation/jquery.validationEngine.js" type="text/javascript" charset="utf-8"></script>

<link type="text/css" href="<?php echo base_url();?>css/custom-theme/jquery-ui-1.8.20.custom.css" rel="stylesheet" />		
<script type="text/javascript" src="<?php echo base_url();?>js/jquery-ui-1.8.20.custom.min.js"></script>
</head>
<body>
<div id="wrapper"> 
	<div id="header">
		<div class="account">
    		<?php 
	    		if (isset($_SESSION['uid']) && $_SESSION['uid'] > 0) {
					echo '<img title="setting" class="setting" src="'.base_url().'css/images/setting.png" />';
	    			echo "Welcome, ".$_SESSION['username'];
	    			$this->load->view('setting');
	    		} 
    		?>
    	</div>
		<img class="logo" src="<?php echo base_url();?>css/images/logo.gif" alt="logo" />
	</div>
	<?php if (isset($menus) && $menus != null) {?>
	<div id="menu-nav">
		<div id="nav">
			<?php $this->load->view('mainmenu'); ?>
		</div>
	</div>
	<?php }?>
	<div id="content-container">
		<?php 
			$margin_left = "";
			if (isset($left)) {
                $classLeft = 'class-left';
                if(isset($content_left) && $content_left == 'report')
                    $classLeft = "class-left-report";
				echo '<div id="content-left" class="'.$classLeft.'">';
				$margin_left = "content-margin-left";
				$this->load->view($left);	
				echo '</div>'; 
			}
		?>
        <?php 
        	$margin_right = "";
			if (isset($right)) {
				echo '<div id="content-right">';
				$margin_right = "content-margin-right";
				$this->load->view($right);
				echo '</div>';	
			}
		?>
		<div id="content-main" class="<?php echo $margin_left.'  '.$margin_right;?>">
        <?php 
            $this->load->view($main);
            if (!isset($_SESSION['uid']) || $_SESSION['uid'] < 1 ){
            	echo '<h3>Human Resource Management System for Friends-International Organization</h3>';
            	echo '<p>HRMS is a kind of web application system used to control information in Organization.</p>';
         ?> 
         	<img class="logo" src="<?php echo base_url();?>css/images/home-feature.jpg" alt="welcome features" />
         <?php  }
        ?>
        </div>
		<div style="clear:both;"></div>
	</div>
	<div id="footer">
		<p>All Right Reserved 2013 Friends-International Organization.</p>
	</div>
</div>
</body>
</html>
